package com.regent.central.infrastructure.web;

/**
 * 中台API基础回应结果对象
 *
 * @author 杨昌沛 646742615@qq.com
 * @date 2018-06-14 10:59
 **/
public class BasicResponse {
    private int code = 0;
    private String message = "OK";

    public BasicResponse() {
    }

    public BasicResponse(int code, String message) {
        this.code = code;
        this.message = message;
    }

    public boolean isSuccess() {
        return code == 0;
    }

    public int getCode() {
        return code;
    }

    public void setCode(int code) {
        this.code = code;
    }

    public String getMessage() {
        return message;
    }

    public void setMessage(String message) {
        this.message = message;
    }
}
